//
//  OLGhostAlertView.h
//
//  Originally created by Radu Dutzan.
//  (c) 2012 Onda.
//

#import <UIKit/UIKit.h>

typedef NS_ENUM(NSUInteger, OLGhostAlertViewPosition) {
    OLGhostAlertViewPositionBottom,
    OLGhostAlertViewPositionCenter,
    OLGhostAlertViewPositionTop
};

@interface OLGhostAlertView : UIView


/**
 *  初始化方法
 *
 *  @param title 标题内容
 *
 *  @return OLGhostAlertView对象
 */
- (id)initWithTitle:(NSString *)title;


/**
 *  初始化方法
 *
 *  @param title   标题
 *  @param message 详细信息
 *
 *  @return OLGhostAlertView对象
 */
- (id)initWithTitle:(NSString *)title
            message:(NSString *)message;

/**
 *  初始化方法
 *
 *  @param title       标题
 *  @param message     详细信息
 *  @param timeout     显示时间
 *  @param dismissible 是否消失
 *
 *  @return OLGhostAlertView对象
 */
- (id)initWithTitle:(NSString *)title
            message:(NSString *)message
            timeout:(NSTimeInterval)timeout
        dismissible:(BOOL)dismissible;

/**
 *  显示
 */
- (void)show;

/**
 *  隐藏
 */
- (void)hide;

@property (nonatomic) OLGhostAlertViewPosition position;
@property (nonatomic, copy) void (^completionBlock)(void);
@property (nonatomic) NSString *title;
@property (nonatomic) NSString *message;
@property (nonatomic) NSTimeInterval timeout;
@property (nonatomic) BOOL dismissible;
@property (nonatomic, readonly, getter=isVisible) BOOL visible;

@end